
let identity = 0;

export const TabNavChanged = (index) => {
  return {
    type:'tab_nav_changed',
    index
  }
}

export const ActionName = (text) => {
  return {
  type:'ActionName',
  id: identity++,
  text,
  }
}

export const showTabBar = (testShow) => {

  if (testShow) {
    console.log('显示 TabBar');
  }else {
    console.log('隐藏 TabBar');
  }
  return {
  type:'findshowTabBar',
  testShow:testShow,
  }
}

export const testAction = (text) => {
  console.log('testAction 能不能调用的到');
  return {
  type:'testAction',
  }
}


// const myAction = {
//   type:'action_name',
//   index: 1,
// }
//
// const actionFunc = (text) => {
//   return {
//     type: 'action_name',
//     index: 2,
//   }
// }
//
// dispatch({type:'action_name',index:2});
// dispatch(myAction);
// dispatch(actionFunc('test'));
//
// const boundAction = (test) => {
//   dispatch(actionFunc(test));
// }
// boundAction('test');
